/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package ep.m002.ui.views;

import com.vaadin.ui.Button;
import com.vaadin.ui.Button.ClickEvent;
import ep.libs.implementations.AbstractModule;
import ep.m009.module.M009Module;

/**
 *
 * @author Spyros
 */
public class M002PharmacistView extends M002View {

    public static final String CAPTION_pending = "Προβολή Εκκρεμών Συνταγών";
    private Button pendingButton;
    
     public M002PharmacistView(AbstractModule module) {
        super(module);
    }

    public M002PharmacistView(AbstractModule module, Object[] args) {
        super(module, args);
    }

    @Override
    protected void initilizeComponents() {
        super.initilizeComponents();
        pendingButton = new Button(CAPTION_pending);
        getButtonsLayout().addComponent(pendingButton);
    }

    @Override
    protected void initializeListeners() {
        super.initializeListeners();
        pendingButton.addListener(new Button.ClickListener() {

            @Override
            public void buttonClick(ClickEvent event) {
                module.getApplication().changeModule(M009Module.class, new Object[]{getController().getPatient()});
            }
        });
    }

    
}
